<template>
  <div class="DRC-biz-list" v-if="true">
    <el-row :gutter="28" v-if="true">
      <template v-for="item in bizOptions">
        <template v-if="item.span===12">
          <el-col class="biz-item" :span="item.span">
            <div
                class="biz-item-inside"
                :class="item.className"
                @click="handleToDetails(item)"
            >
              <div class="info-wrap">
                <p class="name">{{ item.name }}</p>
                <p class="en-name">{{ item.enName }}</p>
                <p class="describe">{{ item.descInfo }}</p>
              </div>
            </div>
          </el-col>
        </template>
        <template v-if="item.span===24">
          <el-col class="biz-item" :span="item.span">
            <div
                class="biz-item-inside"
                :class="item.className"
                @click="handleToDetails(item)"
            >
              <div class="info-wrap">
                <div class="left">
                  <p class="name">{{ item.name }}</p>
                  <p class="en-name">{{ item.enName }}</p>
                </div>
                <div class="right">
                  {{ item.descInfo }}
                </div>
              </div>
            </div>
          </el-col>
        </template>
      </template>
    </el-row>
  </div>
</template>

<script>
export default {
  name: 'DRCbizList',

  componentName: "DRCbizList",

  components: {

  },

  data() {
    return {

    }
  },

  computed: {
    // 业务类型
    bizOptions(){
      return this.$store.getters['DRCbiz/getBizOptions']
    }
  },

  mounted() {

  },

  methods: {
    handleToDetails(row = Object()) {
      console.log(1)
      this.$store.dispatch('DRCbiz/setBizInfo',row);
      let routeName = row?.routeName;
      this.$router.push({
        path: `/${routeName}/${row.id}`
      });
    },
  },
}

</script>

<style scoped lang="scss">
@import "./assets/style";
</style>